<?php
/**
 * Created by IntelliJ IDEA.
 * User: Douma-PC
 * Date: 2019/8/30
 * Time: 10:05
 */
?>

<!doctype html>
<html lang="zh-cn">
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
</head>
<body>
<script type="text/javascript">
var row=20;
var lie=40;
var zjrow=row/2;
var zjlie=lie/2;

    for (q = 0; q <=row; q++) {
        for (w = 0; w <= lie; w++) {
            if (q < zjrow && w < zjlie) {
                if (w - zjlie + q >= 0) {
                    document.write("零");
                } else {
                    document.write("〇");
                }
            }
            if (q < zjrow && w >= zjlie) {
                if (w - zjlie <= q) {
                    document.write("零");
                } else {
                    document.write("〇");
                }
            }
            if (q >= zjrow && w < zjlie) {
                if (w >= q - zjrow) {
                    document.write("零");
                } else {
                    document.write("〇");
                }
            }
            if (q >= zjrow && w >= zjlie) {
                if ((w - zjlie) - zjlie + (q - zjrow) <= 0) {
                    document.write("零");
                }else {
                    document.write("〇");
                }
            }

        }
        document.write("<br/>")
    }
</script>
</body>
</html>
